//package com.wangc.commons.listener;
//
//import com.wangc.commons.interceptor.UserThreadLocal;
//import lombok.extern.slf4j.Slf4j;
//import org.springframework.stereotype.Component;
//
//import javax.servlet.ServletRequestEvent;
//import javax.servlet.ServletRequestListener;
//
///**
// * @program: do-yx-seckillengine
// * @ClassName:RequestListener
// * @description: 请求监听类
// * @author: GYB
// * @create: 2020-05-13 17:05
// **/
//@Component
//@Slf4j
//public class RequestListener implements ServletRequestListener {
//
//    @Override
//    public void requestDestroyed(ServletRequestEvent sre) {
//        log.info("---start request destroy mission---");
//
//        //移除用户
//        UserThreadLocal.removeUser();
//
//        log.info("---end request destroy mission,userThreadLocal was destroyed successful---");
//    }
//
//    @Override
//    public void requestInitialized(ServletRequestEvent sre) {
//    }
//
//}
